//P1303 A+B Problem
#include <iostream>
#include <string>
#include <cmath>
using namespace std;
int c[4016];
string A,B;
string add0(string V,int len){
	int tlen = V.length();
	if(tlen < len){
		for(int i=0;i<len-tlen;i++){
			V='0'+V;
		}
	}
	return V;
}
int main(){
	cin >> A >> B;
	int length = max(A.length(),B.length());
	
	A = add0(A,length);
	B = add0(B,length);
	

	for(int i=0;i<length;i++){
		int t = (A[length-i-1] - '0') + (B[length-i-1] - '0') + c[i];
		c[i] = t%10;
		c[i+1] = t/10;
//		cout << i << " " << c[i] << " " << c[i+1] << endl;
	}
	
	
	int k=0;
	for(int i=length;i>=0;i--){
		if(c[i]==0 && k==0) {
			if(i==0)  cout << 0;
			continue;
		} else {
			k=1;
		}
		cout << c[i];
	}
}
